import request from "@/utils/request";

//用户管理
/**
 * 获取用户列表
 * @param {page,limit,keywords} data
 * @returns
 */

export function consumerList(data) {
  return request({
    url: "/admin/user/userList",
    method: "post",
    data,
  });
}
export function newUserList(data) {
  return request({
    url: "/admin/user/newUserList",
    method: "post",
    data,
  });
}
export function editUserInfo(data) {
  return request({
    url: "/admin/user/upUser",
    method: "post",
    data,
  });
}

//用户操作
/**
 * 用户详细信息
 * @param {id} data
 * @returns
 */
export function userInfo(data) {
  return request({
    url: "/admin/user/userDetails",
    method: "post",
    data,
  });
}

export function userStatus(data) {
  return request({
    url: "/admin/user/sealPost",
    method: "post",
    data,
  });
}

export function setUserTest(data) {
  return request({
    url: "/admin/user/setTest",
    method: "post",
    data,
  });
}

export function userCoupon(data) {
  return request({
    url: "/admin/user/userCoupon",
    method: "post",
    data,
  });
}

export function deluserCoupon(data) {
  return request({
    url: "/admin/user/delUserCoupon",
    method: "post",
    data,
  });
}

export function userBalance(data) {
  return request({
    url: "/admin/user/balanceLog",
    method: "post",
    data,
  });
}

export function userIntegral(data) {
  return request({
    url: "/admin/user/integralLog",
    method: "post",
    data,
  });
}

export function userBoutique(data) {
  return request({
    url: "/admin/user/userBag",
    method: "post",
    data,
  });
}

export function userTX(data) {
  return request({
    url: "/admin/user/messageList",
    method: "post",
    data,
  });
}

export function userMerge(data) {
  return request({
    url: "/admin/user/userCompoundLog",
    method: "post",
    data,
  });
}

export function userProfitandloss(data) {
  return request({
    url: "/admin/user/userYk",
    method: "post",
    data,
  });
}

export function userRecharge(data) {
  return request({
    url: "/admin/user/payLog",
    method: "post",
    data,
  });
}

// 下级用户
export function userLowerUsers(data) {
  return request({
    url: "/admin/user/userLog",
    method: "post",
    data,
  });
}
// 更新下级佣金比例/过期时间
export function updateBiTime(data) {
  return request({
    url: "/admin/user/updateBiTime",
    method: "post",
    data,
  });
}
// 给用户新增下级
export function addUserPost(data) {
  return request({
    url: "/admin/user/addUserPost",
    method: "post",
    data,
  });
}

// 能量球开关1开 0关   每月积分商城购买次数 详情
export function systemConfig(data) {
  return request({
    url: "/admin/config/systemConfig",
    method: "post",
    data,
  });
}

// 能量球开关1开 0关   每月积分商城购买次数 设置
export function setSystemConfig(data) {
  return request({
    url: "/admin/config/setSystemConfig",
    method: "post",
    data,
  });
}

